package com.tcxhb.job.core.schedule.execute;

import com.tcxhb.job.common.model.MiscResult;
import com.tcxhb.job.core.entity.JobRunDTO;

/**
 * @Description:
 * @Auther: tcxhb
 * @Date: 2023/11/6
 */
public interface JobRunExecutor {
    /**
     * @param runDTO
     * @return
     */
    MiscResult run(JobRunDTO runDTO);

    /**
     * 只需要一个instanceId
     *
     * @return
     */
    MiscResult retry(Long instanceId, boolean runOnce);
}
